package patterns.actions.mediator.example;

public abstract class Person {
	String name;
	int age;
	Sex sex;

	int requestAge;

	MarriageAgency agency;

	Person(String name, int age, Sex sex, int requestAge, MarriageAgency agency) {
		this.name = name;
		this.age = age;
		this.sex = sex;
		this.requestAge = requestAge;
		this.agency = agency;
		agency.register(this);
	}

	public void findParter() {
		this.agency.pair(this);
	}
}
